package com.maezia.tdr.common.enums;

import com.maezia.tdr.common.CommonConstant;
import lombok.Getter;

@Getter
public enum StatusCodeEnum {
    SUCCESS(200, CommonConstant.SUCCESS_STATUS_FLAG,"成功!"),
    SYSTEM_ERROR(500, CommonConstant.ERROR_STATUS_FLAG,"系统内部异常!"),

    TOKEN_NOT_NULL(70001, CommonConstant.ERROR_STATUS_FLAG,"Token不能为空！"),
    INVALID_TOKEN_FORMAT(70002, CommonConstant.ERROR_STATUS_FLAG,"Token格式不正确！"),
    TOKEN_EXPIRED(70003, CommonConstant.ERROR_STATUS_FLAG,"Token已过期，请重新获取Token！"),
    INVALID_TOKEN(70004, CommonConstant.ERROR_STATUS_FLAG,"请提供有效的Token参数，以访问此资源！"),
    UNAUTHORIZED_TOKEN(70005, CommonConstant.ERROR_STATUS_FLAG,"提供的Token未被授权，无法访问此资源！"),

    CLIENT_ID_NOT_NULL(80001, CommonConstant.ERROR_STATUS_FLAG,"应用标识不能为空！"),
    CLIENT_SECRET_NOT_NULL(80002, CommonConstant.ERROR_STATUS_FLAG,"应用秘钥不能为空！"),
    CLIENT_ID_NOT_FOUND(80003, CommonConstant.ERROR_STATUS_FLAG,"应用标识不存在！"),
    INVALID_CLIENT_ID(80004, CommonConstant.ERROR_STATUS_FLAG,"无法识别的[appKey]，请提供有效的应用标识！"),
    INVALID_CLIENT_SECRET(80005, CommonConstant.ERROR_STATUS_FLAG,"无法识别的[appSecret]，请提供有效的应用秘钥！"),
    ACCOUNT_LOCKED(80006, CommonConstant.ERROR_STATUS_FLAG,"账号已被锁定！"),
    ACCOUNT_DISABLED(80007, CommonConstant.ERROR_STATUS_FLAG,"账号被禁用！"),

    VEHICLE_ID_NOT_NULL(90001, CommonConstant.ERROR_STATUS_FLAG,"车辆识别id不能为空！"),
    VEHICLE_ID_64_LENGTH(90002, CommonConstant.ERROR_STATUS_FLAG,"车辆识别id长度必须<=64位！"),
    CONSENT_IS_NULL(90003, CommonConstant.ERROR_STATUS_FLAG,"授权状态不能为空！"),
    UNAUTHORIZED_CONSENT(90004, CommonConstant.ERROR_STATUS_FLAG,"未授权状态，请确保您具有正确的授权"),
    UTC_START_TIME_NOT_NULL(90005, CommonConstant.ERROR_STATUS_FLAG,"开始时间不能为空！"),
    UTC_END_TIME_NOT_NULL(90006, CommonConstant.ERROR_STATUS_FLAG,"结束时间格不能为空！"),
    INVALID_UTC_START_TIME_FORMAT(90007, CommonConstant.ERROR_STATUS_FLAG,"开始时间格式不正确，格式为(UTC时间)[yyyy-MM-ddTHH:mm:ssZ]。EX:2023-10-26T08:25:17Z！"),
    INVALID_UTC_END_TIME_FORMAT(90008, CommonConstant.ERROR_STATUS_FLAG,"结束时间格式不正确，格式为(UTC时间)[yyyy-MM-ddTHH:mm:ssZ]。EX:2023-10-26T08:25:17Z！"),
    INVALID_TIME_RANGE(90009, CommonConstant.ERROR_STATUS_FLAG,"开始时间必须小于结束时间！"),
    TOO_MANY_REQUEST(90010, CommonConstant.ERROR_STATUS_FLAG,"您请求的次数过多，请等待一分钟后再试"),
    INVALID_CONSENT_FORMAT(90011, CommonConstant.ERROR_STATUS_FLAG,"授权状态格式不正确");

    private int code;
    private String message;
    private String remark;

    StatusCodeEnum(int code, String message, String remark){
        this.code=code;
        this.message = message;
        this.remark = remark;
    }
}
